package com.lq.educationsystem.socre.entiy;

import java.io.Serializable;

/**
 * 
 * @TableName score_tb
 */
public class ScoreTb implements Serializable {
    /**
     * 成绩id
     */
    private Integer scoreId;

    /**
     * 学生id
     */
    private Integer studentId;

    /**
     * 学生分数
     */
    private Integer score;

    /**
     * 课程id
     */
    private Integer subjectId;

    private static final long serialVersionUID = 1L;

    /**
     * 成绩id
     */
    public Integer getScoreId() {
        return scoreId;
    }

    /**
     * 成绩id
     */
    public void setScoreId(Integer scoreId) {
        this.scoreId = scoreId;
    }

    /**
     * 学生id
     */
    public Integer getStudentId() {
        return studentId;
    }

    /**
     * 学生id
     */
    public void setStudentId(Integer studentId) {
        this.studentId = studentId;
    }

    /**
     * 学生分数
     */
    public Integer getScore() {
        return score;
    }

    /**
     * 学生分数
     */
    public void setScore(Integer score) {
        this.score = score;
    }

    /**
     * 课程id
     */
    public Integer getSubjectId() {
        return subjectId;
    }

    /**
     * 课程id
     */
    public void setSubjectId(Integer subjectId) {
        this.subjectId = subjectId;
    }

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        ScoreTb other = (ScoreTb) that;
        return (this.getScoreId() == null ? other.getScoreId() == null : this.getScoreId().equals(other.getScoreId()))
            && (this.getStudentId() == null ? other.getStudentId() == null : this.getStudentId().equals(other.getStudentId()))
            && (this.getScore() == null ? other.getScore() == null : this.getScore().equals(other.getScore()))
            && (this.getSubjectId() == null ? other.getSubjectId() == null : this.getSubjectId().equals(other.getSubjectId()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getScoreId() == null) ? 0 : getScoreId().hashCode());
        result = prime * result + ((getStudentId() == null) ? 0 : getStudentId().hashCode());
        result = prime * result + ((getScore() == null) ? 0 : getScore().hashCode());
        result = prime * result + ((getSubjectId() == null) ? 0 : getSubjectId().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", scoreId=").append(scoreId);
        sb.append(", studentId=").append(studentId);
        sb.append(", score=").append(score);
        sb.append(", subjectId=").append(subjectId);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}